#include <iostream>
using namespace std;

class A {
	static int sum;
	static int num;
public:
	A() {
		sum += num;
		num++;
	}
	static int result() {
		return sum;
	}
};

int A::sum = 0;
int A::num = 1;

int main()
{
	A * Aarray = new A[100];
	cout << A::result() << endl;
	delete Aarray;
	cout << A::result() << endl;
	return 0;
}
